#ifndef TRANSOR_H
#define TRANSOR_H
#include <QStringList>
#include <QList>
#include <QString>

//Transliterator is a Devanagari transliteration convertor.

class Transliterator
{
public:
    Transliterator();

    QString itrans_to_iast(QString src);
    QString iast_to_itrans(QString src);

    QString itrans_to_hk(QString src);
    QString hk_to_itrans(QString src);

    QString slp1_to_itrans(QString src);
    QString itrans_to_slp1(QString src);

    QString velthuis_to_itrans(QString src);
    QString itrans_to_velthuis(QString src);

    QString itrans_to_iso15919(QString src);
    QString iso15919_to_itrans(QString src);
    QString itrans_to_deva(QString src);
    QString deva_to_itrans(QString src);

    bool is_devanagari(QString text);
private:
    QString filter_itrans(QString);
    QString convert(QString src, QStringList src_map, QStringList dest_map);
    QStringList itrans;
    QStringList hk;
    QStringList iast;
    QStringList slp1;
    QStringList velthuis;
    QStringList iso15919;
    QList<int> unicode;
};

#endif // TRANSOR_H
